<%@ Page Language="c#" Inherits="WPS.Modules.StyleLibrary.TableEdit" CodeFile="TableEdit.aspx.cs" %>
<%@ Register TagPrefix="wps" Tagname="PageMessageControl" Src="./PageMessageControl.ascx" %><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
	<title>{#stylelibrary_dlg.table_style_title}</title>

	<script type="text/javascript" src="/Default/Scripts/jquery/jquery-1.9.1.min.js"></script>
	<script type="text/javascript" src="../../tiny_mce_popup.js"></script>
	<script type="text/javascript" src="../../utils/mctabs.js"></script>
	<script type="text/javascript" src="../../utils/form_utils.js"></script>
	<script type="text/javascript" src="../../utils/editable_selects.js"></script>
	<script type="text/javascript" src="../../utils/validate.js"></script>

	<script type="text/javascript" src="js/tableedit.js"></script>
	<script type="text/javascript" src="js/StyleSheet.js"></script>
	<script type="text/javascript" src="panels/panels.js"></script>

	<link rel="stylesheet" type="text/css" media="all" href="css/dialog.css" />
	<link rel="stylesheet" type="text/css" media="all" href="css/borderpicker.css" />

	<script type="text/javascript">

var frameLoaded = false; // Page load semafors
var dialogLoaded = false;
var cssLoaded = false;

// Original css values are generated to this array.
var designer = new stylesDesigner();

<%= LoadedStylesJS %>

</script>

</head>
<body>

<form runat="server" id="Form1">
<input type="hidden" id="hdnOriginalName" name="hdnOriginalName" value="<%= OriginalName %>"/>
<input type="hidden" id="hdnCssOutput" name="hdnCssOutput" value="<%= CssOutput %>"/>
<input type="hidden" id="hdnOverviewStyles" name="hdnOverviewStyles" value="<%= OverviewStyles %>"/>
<input type="hidden" id="hdnTask" name="hdnTask" value="type" />

<wps:PageMessageControl runat="server" ID="pgmPageMessage" />

<div class="wrappreview">

<div class="wrapcontrolside">
	<div class="controlside">

<h1 class="title">{#stylelibrary_dlg.table_style_title}</h1>

<div id="mainsettings">
	{#stylelibrary_dlg.style_name}: 
	<input type="text" name="txtNewName" id="txtNewName" value="<%= NewName %>"/><br />

	<input type="checkbox" name="chkCollapse" id="chkCollapse" onclick="updateCollapse()" />
	<label for="chkCollapse">{#stylelibrary_dlg.border_collapse}</label>
	&nbsp;&nbsp;
	<span id="tablecellspacing">
		<label for="ddlCellSpacing">{#stylelibrary_dlg.cell_spacing}:</label>
		<input id="ddlCellSpacing" type="number" class="num" onchange="updateCollapse()" min="0" />
	</span>
</div>

<div id="tasks" class="tabs">
	<ul>
		<li id="task_tablestyle"><span><a href="#" onclick="mcTabs.showTab(this);setTask('tablestyle');return false;">{#stylelibrary_dlg.task_table_style}</a></span></li>
		<li id="task_cell"><span><a href="#" onclick="mcTabs.showTab(this);setTask('cell');return false;">{#stylelibrary_dlg.task_cell}</a></span></li>
		<li id="task_alt"><span><a href="#" onclick="mcTabs.showTab(this);setTask('alt');return false;">{#stylelibrary_dlg.task_alt_row}</a></span></li>
		<li id="task_header"><span><a href="#" onclick="mcTabs.showTab(this);setTask('header');return false;">{#stylelibrary_dlg.task_header}</a></span></li>
		<li id="task_headeralt"><span><a href="#" onclick="mcTabs.showTab(this);setTask('headeralt');return false;">{#stylelibrary_dlg.task_header_alt}</a></span></li>
		<li id="task_caption"><span><a href="#" onclick="mcTabs.showTab(this);setTask('caption');return false;">{#stylelibrary_dlg.task_caption}</a></span></li>
	</ul>
</div>

<div id="taskpanels">
<!-- Panels -->
<!--#include file="panels/pickfont.html" -->
<!--#include file="panels/pickborder.html" -->
<!--#include file="panels/pickcellprop.html" -->
</div>

<!--#include file="panels/conflict.html" -->

	<div>
		<p><em>{#stylelibrary_dlg.editwarning}</em></p>
		<asp:button id="btnSave" runat="server" CssClass="updateButton"  Text="{#stylelibrary_dlg.save}" OnClick="btnSave_Click" OnInit="btnSave_Init"/>&nbsp;
		<input type="button" id="cancel" value="{#cancel}" onclick="if(confirm(tinyMCEPopup.editor.getLang('stylelibrary_dlg.discard_changes'))) { document.location.href = 'Overview.aspx?styles=tables'; }" />
	</div>
	</div>
</div>

<div class="previewside">
	<!--#include file="panels/previewsettings.html" -->

	<iframe class="previewframe" src="Chunks/DemoTable.html" id="demoFrame" name="demoFrame"></iframe>
</div>


</div>


</form>

</body>
</html>
